<template>
  <div class="home-container">
    <!-- 主要内容区域 -->
    <div class="main-content">
      <!-- 学科分类和轮播图 -->
      <div class="top-section">
        <SubjectCategories class="subject-categories" />
        <BannerCarousel class="banner-carousel" />
      </div>
      
      <!-- 常用功能 -->
      <CommonFeatures />
      
      <!-- 课程推荐 -->
      <CourseRecommendation />
      
      <!-- 全部课程 -->
      <AllCourses />
    </div>
  </div>
</template>

<script setup>
import SubjectCategories from '@/components/home/SubjectCategories.vue';
import BannerCarousel from '@/components/home/BannerCarousel.vue';
import CommonFeatures from '@/components/home/CommonFeatures.vue';
import CourseRecommendation from '@/components/home/CourseRecommendation.vue';
import AllCourses from '@/components/home/AllCourses.vue';
</script>

<style lang="scss" scoped>
.home-container {
  min-height: 100vh;
  background-color: #f5f7fa;
  display: flex;
  flex-direction: column;
  
  .main-content {
    flex: 1;
    width: 1200px;
    margin: 20px auto;
    
    .top-section {
      display: flex;
      gap: 20px;
      margin-bottom: 20px;
      
      .subject-categories {
        flex: 0 0 240px;
        height: 440px;
        overflow: hidden;
      }
      
      .banner-carousel {
        flex: 1;
        height: 440px;
      }
    }
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
</style> 